package com.hfmall.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hfmall.entity.HfCategory;
import com.hfmall.entity.HfGoodsinfo;
import com.baomidou.mybatisplus.extension.service.IService;
import com.hfmall.entity.UtilPageGoodsinfoVO;

import javax.servlet.http.HttpServletRequest;
import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author liclo
 * @since 2021-08-12
 */
public interface IHfGoodsinfoService extends IService<HfGoodsinfo> {
    // 分页查询goodsInfo
    Page<HfGoodsinfo> getGoodsInfo(Integer current, Integer size);

    //根据分类id查询 商品共性表
    List< HfGoodsinfo > getHfGoodsinfoByPid(int pid);

    //查询热门商品,num给定list数量
    Page< HfGoodsinfo > getHot(int num);

    Page<HfGoodsinfo> getListByCategory(Integer page,Integer num,Integer pid);

    Page<HfGoodsinfo> getByCondition(Integer current, Integer size, HfGoodsinfo goodsinfo);

    void add(HttpServletRequest request);

    /**
     *
     * @param (UtilPageGoodsinfoVO) 页码/每页个数/条件

     * @return 根据条件查询商品(规格值数组,分类类别)
     */
    UtilPageGoodsinfoVO getHfGoodsinfoListByCategoryL3Id(UtilPageGoodsinfoVO utilPageGoodsinfoVO);
    /**根据Lv3级分类查询其所对应商品*/
    List<HfGoodsinfo> getAllGoodsinfoByByCategoryL3Id(List<HfCategory> hfCategoryLv3);

    /**
     * 根据字符串msg 查询goodsName
     */
    UtilPageGoodsinfoVO  getGoodsinfoListByLike(String msg,Integer page,Integer size);





}
